Mainstream computer architectures in the future will rely on concurrency as a way to improve performance. This is in contrast to the past thirty years or so, which improved performance with increases in clock frequency and advances in superscalar execution techniques. In order for software to be successful in new architectures, programmers are transitioning to a different way of approaching software development and performance work. For example, simply reducing the number of cycles an algorithm requires to compute an answer does not necessarily translate into the fastest possible algorithm that scales well as new processors are adopted. This applies to client and server workloads alike. Multiple-core processors are already widely available, such as dual-core and quad-core processors from major manufacturers, and predictions of many more cores in the near future. Each core can also carry several hardware threads to mask memory latencies. This trend will continue into the foreseeable future, with the number of cores expected to double every two years or so.
Concurrent computing is the simultaneous execution of multiple interacting computational tasks in multiple processor environments such as multi-core processors. These tasks may be implemented as separate programs, or as a set of processes or threads created by a single software application. Concurrent programming is destined to create an entire new wave of software applications. For applications to run faster on the new hardware, developers will need to adopt concurrent programming. Moreover, there is a category of interesting applications and algorithms that only become feasible with the amount of compute power this transition will bring, ranging from rich immersive experiences complete with vision and speech integration to deeper semantic analysis, understanding, and mining of information.
In connection with concurrent programming, dataflow programming is a common concurrent, or parallel, programming idiom. Dataflow is a software architecture based on the idea that changing the value of a variable can automatically force recalculation of the values of other variables. For example, spreadsheets are perhaps the most widespread embodiment of dataflow. In a spreadsheet, a user can specify a cell formula that depends on other cells. When one or more of those cells are updated, the values in the other cells are automatically recalculated.
Dataflow programming in parallel architectures uses data dependence as the mechanism for synchronization of data. For example, code can wait for the completion of a computation in order to retrieve the resulting value. This is commonly represented in programming models with a “future” type. Managed programming environments, such as Microsoft .NET, can include a Future<T> type that is meant to represent a value to be computed in the future. An example can be: